Naanou
Class frmVis

Form for holding visualisation control and manipulating it

Field Summary
System.Drawing.Color BackFingerColour
System.Windows.Forms.Button btnReSync
System.Windows.Forms.Button btnSetRefreshRate
System.Drawing.Color CacheColour
System.Drawing.Pen CacheHitPen
int cacheSize
System.ComponentModel.Container components
System.Drawing.Color DefaultColour
int exPointerSize
System.Drawing.Color FingerColour
int fingerSize
Naanou.Indexer indexer
System.Drawing.Color KeyStoreColour
System.Drawing.Pen KeyStorePen
System.Windows.Forms.Label label1
double mappingRatio
System.Collections.Hashtable nodeToDot
System.Windows.Forms.NumericUpDown numericUpDown1
int pointerSize
System.Drawing.Color PredColour
System.Drawing.Color SuccColour
Naanou.Vis.Viewer viewer

Fields inherited from class System.Windows.Forms.ScrollableControl
scrollPosition

Fields inherited from class System.Windows.Forms.Control
window

Constructor Summary
frmVis()
         Constructor

Properties inherited from class System.Windows.Forms.Form
AcceptButton, ActiveMdiChild, AllowTransparency, AutoScale, AutoScaleBaseSize, AutoScroll, BackColor, CancelButton, ClientSize, ControlBox, CreateParams, DefaultImeMode, DefaultSize, DesktopBounds, DesktopLocation, DialogResult, FormBorderStyle, HelpButton, Icon, IsMdiChild, IsMdiContainer, IsRestrictedWindow, KeyPreview, MaximizeBox, MaximizedBounds, MaximumSize, MdiChildren, MdiParent, Menu, MergedMenu, MinimizeBox, MinimumSize, Modal, Opacity, OwnedForms, Owner, ShowInTaskbar, Size, SizeGripStyle, StartPosition, TabIndex, TopLevel, TopMost, TransparencyKey, WindowState

Properties inherited from class System.Windows.Forms.ContainerControl
ActiveControl, BindingContext, ParentForm

Properties inherited from class System.Windows.Forms.ScrollableControl
AutoScrollMargin, AutoScrollMinSize, AutoScrollPosition, DisplayRectangle, DockPadding, HScroll, VScroll

Properties inherited from class System.Windows.Forms.Control
AccessibilityObject, AccessibleDefaultActionDescription, AccessibleDescription, AccessibleName, AccessibleRole, AllowDrop, Anchor, BackgroundImage, Bottom, Bounds, CanFocus, CanSelect, Capture, CausesValidation, ClientRectangle, CompanyName, ContainsFocus, ContextMenu, Controls, Created, Cursor, DataBindings, Disposing, Dock, Enabled, Focused, Font, FontHeight, ForeColor, Handle, HasChildren, Height, ImeMode, InvokeRequired, IsAccessible, IsDisposed, IsHandleCreated, Left, Location, Name, Parent, ProductName, ProductVersion, RecreatingHandle, Region, RenderRightToLeft, ResizeRedraw, Right, RightToLeft, ShowFocusCues, ShowKeyboardCues, Site, TabStop, Tag, Text, Top, TopLevelControl, Visible, Width, WindowTarget

Properties inherited from class System.ComponentModel.Component
Container, DesignMode, Events

Method Summary
void AddCacheEntries(Naanou.LookupService.NodeAddress[] entries)
void AddFingerEntries(Naanou.LookupService.NodeAddress[] entries, bool forward)
void btnFPS_Click(object sender, System.EventArgs e)
void btnReSync_Click(object sender, System.EventArgs e)
void Dispose(bool disposing)
         Clean up any resources being used.
void frmVis_Activated(object sender, System.EventArgs e)
void frmVis_Closing(object sender, System.ComponentModel.CancelEventArgs e)
void frmVis_Deactivate(object sender, System.EventArgs e)
void frmVis_Load(object sender, System.EventArgs e)
void frmVis_Resize(object sender, System.EventArgs e)
Naanou.Vis.Dot GetDot(Naanou.Common.Address address)
         Looks up an existing dot for an address, or creates a new one. Returns null if the address is empty
Naanou.Vis.Dot GetDot(string name, Naanou.Common.Hash hash)
double IdToDegrees(Naanou.Common.Hash id)
         Maps node ids to the visualisation space
void InitializeComponent()
         Required method for Designer support - do not modify the contents of this method with the code editor.
void OnCacheAdded(object sender, Naanou.LookupService.NodeEventArgs args)
void OnCacheHit(object sender, Naanou.LookupService.NodeEventArgs args)
void OnFingerKeyChanged(object sender, Naanou.LookupService.FingerKeyChangeArgs args)
void OnKeyAdded(object sender, Naanou.LookupService.KeyAddedEventArgs args)
void OnPredecessorChange(Naanou.LookupService.Node sender, Naanou.LookupService.AddressChangeArgs args)
void OnSuccessorChange(Naanou.LookupService.Node sender, Naanou.LookupService.AddressChangeArgs args)
void OnUpDownChange(object sender, System.EventArgs e)
System.Drawing.Pen RandomPen()
void ReSync()

Methods inherited from class System.Windows.Forms.Form
Activate, ActivateMdiChild, AddOwnedForm, AdjustFormScrollbars, ApplyAutoScaling, AssignParent, CenterToParent, CenterToScreen, Close, CreateControlsInstance, CreateHandle, DefWndProc, FocusInternal, LayoutMdi, OnActivated, OnClosed, OnClosing, OnCreateControl, OnDeactivate, OnFontChanged, OnHandleCreated, OnHandleDestroyed, OnInputLanguageChanged, OnInputLanguageChanging, OnLoad, OnMaximizedBoundsChanged, OnMaximumSizeChanged, OnMdiChildActivate, OnMenuComplete, OnMenuStart, OnMinimumSizeChanged, OnPaint, OnResize, OnStyleChanged, OnTextChanged, OnVisibleChanged, ProcessCmdKey, ProcessDialogKey, ProcessKeyPreview, ProcessTabKey, RecreateHandleCore, RemoveOwnedForm, ScaleCore, Select, SetBoundsCore, SetClientSizeCore, SetDesktopBounds, SetDesktopLocation, SetVisibleCore, ShouldSerializeAutoScaleBaseSize, ShouldSerializeSize, ShowDialog, ShowDialog, ToString, UpdateDefaultButton, WndProc

Methods inherited from class System.Windows.Forms.ContainerControl
IContainerControl.ActivateControl, OnControlRemoved, ProcessDialogChar, ProcessMnemonic, Validate

Methods inherited from class System.Windows.Forms.ScrollableControl
GetScrollState, OnLayout, OnMouseWheel, ScrollControlIntoView, SetAutoScrollMargin, SetDisplayRectLocation, SetScrollState

Methods inherited from class System.Windows.Forms.Control
AccessibilityNotifyClients, BeginInvoke, BeginInvoke, BringToFront, CanSelectCore, Contains, CreateAccessibilityInstance, CreateControl, CreateGraphics, DestroyHandle, DisposeAxControls, DoDragDrop, EndInvoke, FindForm, Focus, GetChildAtPoint, GetContainerControl, GetNextControl, GetStyle, GetTopLevel, GetVisibleCore, Hide, InitializeDCForWmCtlColor, InitLayout, Invalidate, Invalidate, Invalidate, Invalidate, Invalidate, Invalidate, Invoke, Invoke, InvokeGotFocus, InvokeLostFocus, InvokeOnClick, InvokePaint, InvokePaintBackground, IsInputChar, IsInputKey, NotifyInvalidate, NotifyValidationResult, OnBackColorChanged, OnBackgroundImageChanged, OnBindingContextChanged, OnCausesValidationChanged, OnChangeUICues, OnClick, OnContextMenuChanged, OnControlAdded, OnCursorChanged, OnDockChanged, OnDoubleClick, OnDragDrop, OnDragEnter, OnDragLeave, OnDragOver, OnEnabledChanged, OnEnter, OnForeColorChanged, OnGiveFeedback, OnGotFocus, OnHelpRequested, OnImeModeChanged, OnInvalidated, OnKeyDown, OnKeyPress, OnKeyUp, OnLeave, OnLocationChanged, OnLostFocus, OnMouseDown, OnMouseEnter, OnMouseHover, OnMouseLeave, OnMouseMove, OnMouseUp, OnMove, OnNotifyMessage, OnPaintBackground, OnParentBackColorChanged, OnParentBackgroundImageChanged, OnParentBindingContextChanged, OnParentChanged, OnParentEnabledChanged, OnParentFontChanged, OnParentForeColorChanged, OnParentRightToLeftChanged, OnParentVisibleChanged, OnQueryContinueDrag, OnRightToLeftChanged, OnSizeChanged, OnSystemColorsChanged, OnTabIndexChanged, OnTabStopChanged, OnValidated, OnValidating, PerformLayout, PerformLayout, PointToClient, PointToScreen, PreProcessMessage, ProcessKeyEventArgs, ProcessKeyMessage, RaiseDragEvent, RaiseKeyEvent, RaiseMouseEvent, RaisePaintEvent, RecreateHandle, RectangleToClient, RectangleToScreen, Refresh, ResetBackColor, ResetBindings, ResetCursor, ResetFont, ResetForeColor, ResetImeMode, ResetMouseEventArgs, ResetRightToLeft, ResetText, ResumeLayout, ResumeLayout, RtlTranslateAlignment, RtlTranslateAlignment, RtlTranslateAlignment, RtlTranslateContent, RtlTranslateHorizontal, RtlTranslateLeftRight, Scale, Scale, Select, SelectNextControl, SendToBack, SetBounds, SetBounds, SetStyle, SetTopLevel, ShouldSerializeBackColor, ShouldSerializeCursor, ShouldSerializeFont, ShouldSerializeForeColor, ShouldSerializeImeMode, ShouldSerializeLocation, ShouldSerializeRightToLeft, ShouldSerializeText, Show, SuspendLayout, UnsafeNativeMethods+IOleControl.FreezeEvents, UnsafeNativeMethods+IOleControl.GetControlInfo, UnsafeNativeMethods+IOleControl.OnAmbientPropertyChange, UnsafeNativeMethods+IOleControl.OnMnemonic, UnsafeNativeMethods+IOleInPlaceActiveObject.ContextSensitiveHelp, UnsafeNativeMethods+IOleInPlaceActiveObject.EnableModeless, UnsafeNativeMethods+IOleInPlaceActiveObject.GetWindow, UnsafeNativeMethods+IOleInPlaceActiveObject.OnDocWindowActivate, UnsafeNativeMethods+IOleInPlaceActiveObject.OnFrameWindowActivate, UnsafeNativeMethods+IOleInPlaceActiveObject.ResizeBorder, UnsafeNativeMethods+IOleInPlaceActiveObject.TranslateAccelerator, UnsafeNativeMethods+IOleInPlaceObject.ContextSensitiveHelp, UnsafeNativeMethods+IOleInPlaceObject.GetWindow, UnsafeNativeMethods+IOleInPlaceObject.InPlaceDeactivate, UnsafeNativeMethods+IOleInPlaceObject.ReactivateAndUndo, UnsafeNativeMethods+IOleInPlaceObject.SetObjectRects, UnsafeNativeMethods+IOleInPlaceObject.UIDeactivate, UnsafeNativeMethods+IOleObject.Advise, UnsafeNativeMethods+IOleObject.Close, UnsafeNativeMethods+IOleObject.DoVerb, UnsafeNativeMethods+IOleObject.EnumAdvise, UnsafeNativeMethods+IOleObject.EnumVerbs, UnsafeNativeMethods+IOleObject.GetClientSite, UnsafeNativeMethods+IOleObject.GetClipboardData, UnsafeNativeMethods+IOleObject.GetExtent, UnsafeNativeMethods+IOleObject.GetMiscStatus, UnsafeNativeMethods+IOleObject.GetMoniker, UnsafeNativeMethods+IOleObject.GetUserClassID, UnsafeNativeMethods+IOleObject.GetUserType, UnsafeNativeMethods+IOleObject.InitFromData, UnsafeNativeMethods+IOleObject.IsUpToDate, UnsafeNativeMethods+IOleObject.OleUpdate, UnsafeNativeMethods+IOleObject.SetClientSite, UnsafeNativeMethods+IOleObject.SetColorScheme, UnsafeNativeMethods+IOleObject.SetExtent, UnsafeNativeMethods+IOleObject.SetHostNames, UnsafeNativeMethods+IOleObject.SetMoniker, UnsafeNativeMethods+IOleObject.Unadvise, UnsafeNativeMethods+IOleWindow.ContextSensitiveHelp, UnsafeNativeMethods+IOleWindow.GetWindow, UnsafeNativeMethods+IPersist.GetClassID, UnsafeNativeMethods+IPersistPropertyBag.GetClassID, UnsafeNativeMethods+IPersistPropertyBag.InitNew, UnsafeNativeMethods+IPersistPropertyBag.Load, UnsafeNativeMethods+IPersistPropertyBag.Save, UnsafeNativeMethods+IPersistStorage.GetClassID, UnsafeNativeMethods+IPersistStorage.HandsOffStorage, UnsafeNativeMethods+IPersistStorage.InitNew, UnsafeNativeMethods+IPersistStorage.IsDirty, UnsafeNativeMethods+IPersistStorage.Load, UnsafeNativeMethods+IPersistStorage.Save, UnsafeNativeMethods+IPersistStorage.SaveCompleted, UnsafeNativeMethods+IPersistStreamInit.GetClassID, UnsafeNativeMethods+IPersistStreamInit.GetSizeMax, UnsafeNativeMethods+IPersistStreamInit.InitNew, UnsafeNativeMethods+IPersistStreamInit.IsDirty, UnsafeNativeMethods+IPersistStreamInit.Load, UnsafeNativeMethods+IPersistStreamInit.Save, UnsafeNativeMethods+IQuickActivate.GetContentExtent, UnsafeNativeMethods+IQuickActivate.QuickActivate, UnsafeNativeMethods+IQuickActivate.SetContentExtent, UnsafeNativeMethods+IViewObject.Draw, UnsafeNativeMethods+IViewObject.Freeze, UnsafeNativeMethods+IViewObject.GetAdvise, UnsafeNativeMethods+IViewObject.GetColorSet, UnsafeNativeMethods+IViewObject.SetAdvise, UnsafeNativeMethods+IViewObject.Unfreeze, UnsafeNativeMethods+IViewObject2.Draw, UnsafeNativeMethods+IViewObject2.Freeze, UnsafeNativeMethods+IViewObject2.GetAdvise, UnsafeNativeMethods+IViewObject2.GetColorSet, UnsafeNativeMethods+IViewObject2.GetExtent, UnsafeNativeMethods+IViewObject2.SetAdvise, UnsafeNativeMethods+IViewObject2.Unfreeze, Update, UpdateBounds, UpdateBounds, UpdateBounds, UpdateStyles, UpdateStylesCore, UpdateZOrder

Methods inherited from class System.ComponentModel.Component
Dispose, Finalize, GetService

Methods inherited from class System.MarshalByRefObject
CreateObjRef, GetLifetimeService, InitializeLifetimeService

Methods inherited from class System.Object
Equals, GetHashCode, GetType, MemberwiseClone

Events inherited from class System.Windows.Forms.Form
Activated, Closed, Closing, Deactivate, InputLanguageChanged, InputLanguageChanging, Load, MaximizedBoundsChanged, MaximumSizeChanged, MdiChildActivate, MenuComplete, MenuStart, MinimumSizeChanged

Events inherited from class System.Windows.Forms.Control
BackColorChanged, BackgroundImageChanged, BindingContextChanged, CausesValidationChanged, ChangeUICues, Click, ContextMenuChanged, ControlAdded, ControlRemoved, CursorChanged, DockChanged, DoubleClick, DragDrop, DragEnter, DragLeave, DragOver, EnabledChanged, Enter, FontChanged, ForeColorChanged, GiveFeedback, GotFocus, HandleCreated, HandleDestroyed, HelpRequested, ImeModeChanged, Invalidated, KeyDown, KeyPress, KeyUp, Layout, Leave, LocationChanged, LostFocus, MouseDown, MouseEnter, MouseHover, MouseLeave, MouseMove, MouseUp, MouseWheel, Move, Paint, ParentChanged, QueryAccessibilityHelp, QueryContinueDrag, Resize, RightToLeftChanged, SizeChanged, StyleChanged, SystemColorsChanged, TabIndexChanged, TabStopChanged, TextChanged, Validated, Validating, VisibleChanged

Events inherited from class System.ComponentModel.Component
Disposed


Field Detail

BackFingerColour

private System.Drawing.Color BackFingerColour


btnReSync

private System.Windows.Forms.Button btnReSync


btnSetRefreshRate

private System.Windows.Forms.Button btnSetRefreshRate


CacheColour

private System.Drawing.Color CacheColour


CacheHitPen

private System.Drawing.Pen CacheHitPen


cacheSize

private int cacheSize


components

private System.ComponentModel.Container components


DefaultColour

private System.Drawing.Color DefaultColour


exPointerSize

private int exPointerSize


FingerColour

private System.Drawing.Color FingerColour


fingerSize

private int fingerSize


indexer

private Naanou.Indexer indexer


KeyStoreColour

private System.Drawing.Color KeyStoreColour


KeyStorePen

private System.Drawing.Pen KeyStorePen


label1

private System.Windows.Forms.Label label1


mappingRatio

private double mappingRatio


nodeToDot

private System.Collections.Hashtable nodeToDot


numericUpDown1

private System.Windows.Forms.NumericUpDown numericUpDown1


pointerSize

private int pointerSize


PredColour

private System.Drawing.Color PredColour


SuccColour

private System.Drawing.Color SuccColour


viewer

private Naanou.Vis.Viewer viewer

Constructor Detail

frmVis

public frmVis()

Constructor

Method Detail

AddCacheEntries

public void AddCacheEntries(Naanou.LookupService.NodeAddress[] entries)


AddFingerEntries

public void AddFingerEntries(Naanou.LookupService.NodeAddress[] entries,
                             bool forward)


btnFPS_Click

private void btnFPS_Click(object sender,
                          System.EventArgs e)


btnReSync_Click

private void btnReSync_Click(object sender,
                             System.EventArgs e)


Dispose

protected void Dispose(bool disposing)

Clean up any resources being used.


frmVis_Activated

private void frmVis_Activated(object sender,
                              System.EventArgs e)


frmVis_Closing

private void frmVis_Closing(object sender,
                            System.ComponentModel.CancelEventArgs e)


frmVis_Deactivate

private void frmVis_Deactivate(object sender,
                               System.EventArgs e)


frmVis_Load

private void frmVis_Load(object sender,
                         System.EventArgs e)


frmVis_Resize

private void frmVis_Resize(object sender,
                           System.EventArgs e)


GetDot

private Naanou.Vis.Dot GetDot(Naanou.Common.Address address)

Looks up an existing dot for an address, or creates a new one. Returns null if the address is empty

Parameters:
address -
Returns:

GetDot

private Naanou.Vis.Dot GetDot(string name,
                              Naanou.Common.Hash hash)


IdToDegrees

private double IdToDegrees(Naanou.Common.Hash id)

Maps node ids to the visualisation space

Parameters:
id -
Returns:

InitializeComponent

private void InitializeComponent()

Required method for Designer support - do not modify the contents of this method with the code editor.


OnCacheAdded

private void OnCacheAdded(object sender,
                          Naanou.LookupService.NodeEventArgs args)


OnCacheHit

private void OnCacheHit(object sender,
                        Naanou.LookupService.NodeEventArgs args)


OnFingerKeyChanged

public void OnFingerKeyChanged(object sender,
                               Naanou.LookupService.FingerKeyChangeArgs args)


OnKeyAdded

private void OnKeyAdded(object sender,
                        Naanou.LookupService.KeyAddedEventArgs args)


OnPredecessorChange

public void OnPredecessorChange(Naanou.LookupService.Node sender,
                                Naanou.LookupService.AddressChangeArgs args)


OnSuccessorChange

public void OnSuccessorChange(Naanou.LookupService.Node sender,
                              Naanou.LookupService.AddressChangeArgs args)


OnUpDownChange

private void OnUpDownChange(object sender,
                            System.EventArgs e)


RandomPen

private System.Drawing.Pen RandomPen()


ReSync

private void ReSync()